import React,{ Component } from 'react'
import { LegionsProModal } from 'legions-pro-design';
import { bind,observer } from 'legions/store-react';
import ProjectStore from '../../stores/projectStore';
import { InstanceProModal } from 'legions-pro-design/es/LegionsProModal/interface';
interface IProps {
    onOk?: (e: React.MouseEvent<any,MouseEvent>) => void
    // @ts-ignore
    children?: any;
    onReady: (value: InstanceProModal) => void
    store?: ProjectStore
}
/* @bind({ store: ProjectStore })
@observer */
export class BasicModal extends React.Component<IProps> {
    constructor(props: IProps) {
        super(props);
    }
    render() {
        return (

            <LegionsProModal
                onOk={(e) => {
                    this.props.onOk && this.props.onOk(e)
                }}
                onReady={(value) => {
                    /* */
                    this.props.onReady(value)
                }}>
                {this.props.children}
            </LegionsProModal>
        );
    }
}